<template>

    <C :arr="[1, 2, 3]" :name="title"></C>

</template>

<script setup lang='ts'>
import { ref } from 'vue';
import C from "./C.vue"
let title = "Hello World"
const getName = (name: string) => {
    console.log(emit);

}
</script>
<style scoped></style>

<!-- <template>
    <p>child</p>

    <div>{{ name }}</div>
    <div>{{ arr }}</div>

    <button @click="send">click</button>
</template>

<script setup lang='ts'>
import { ref } from 'vue';

const emit = defineEmits(['on-click'])

const send = () => {
    // emit参数是名称，第二个参数回调函数的参数
    emit('on-click', 'emit')
}
const data = defineProps<{
    name: string,
    arr: number[]
}>() -->
